Page({
  data: {
    indicatorDots: true,
    indicatorColor: '#d1e5fb',
    indicatorActiveColor: '#1b7dec',
    autoplay: true,
    interval: 2000,
    duration: 1000,
    indexImgs: [],
    seq: 0,
    news: [],
    taglist: [],
    sts: 0,


    //realData
    nowRole:'',
  },
  toOrderList(){
    wx.navigateTo({
      url: '/pages/order/orderList/orderList',
    })
  },
  toCreateOrder(){
    wx.navigateTo({
      url: '/pages/order/createOrder/createOrder',
    })
  },
  // 跳转搜索页
  toSearchPage: function() {
    wx.navigateTo({
      url: '/pages/search-page/search-page',
    })
  },
  //跳转企业介绍
  toClassifyPage: function(e) {
    var url = '/pages/classify/classify?sts=' + e.currentTarget.dataset.sts;
    var id = e.currentTarget.dataset.id;
    var title = e.currentTarget.dataset.title;
    if (id) {
      url += "&tagid=" + id + "&title=" + title;
    }
    wx.navigateTo({
      url: url
    })
  },
    //跳转附近门店
    toLimitedTimeOffer: function(e) {
      wx.showToast({
        icon:"none",
        title: '附近门店'
      })
    },
    toCouponCenter: function() {
      wx.showToast({
        icon:"none",
        title: '视频专区'
      })
    },
    //跳转公告列表页面
  onNewsPage: function() {
    wx.navigateTo({
      url: '/pages/news/news',
    })
  },
  onLoad(){
    this.setData({
      nowRole:wx.getStorageSync('roleName') || new String()
    })
  }

})